// pages/house/house.ts
Page({
  async onLoad() {
    let res = await wx.http.get('/room')
    this.setData({
      list: res.data
    })
  },
  back() {
    wx.switchTab({
      url: '/pages/home/home'
    })
  },
  fangwu(event: any) {
    wx.navigateTo({
      url: '/pages/housemsg/housemsg?id=' + event.currentTarget.dataset.id
    })
  },
  add() {
    wx.navigateTo({
      url: '/pages/addhouse/addhouse'
    })
  }
})
